POV-Ray : Newsgroups : povray.general : Bezier problem : Re: Bezier problem Server Time
9 Aug 2024 23:28:28 EDT (-0400)
  Re: Bezier problem  
From: John VanSickle
Date: 15 Apr 2000 19:38:19
Message: <38F9005F.7562EA25@erols.com>
Sebastian Strand wrote:
> 
> Hi,
> 
> I'm making a macro that involves a bezier_spline prism. What I need to know
> is how I should place the control points of a bezier spline to make it
> resemble a quarter circle as closely as possible.
> 
> Just to clarify, this is how they points are placed:
> O-------o
> 
>              o
>              |
>              |
>              |
>              O
> 
> Big O's are endpoints, small o's control points. If I place the control
> points halfway to the corner I come pretty close to a circle, but I hope
> there is a more mathematical way to do it, I'm not very fond of guessing :)

There is.  If r is the radius of the quarter circle, then the distance from
the little-o control points to its big-O control point will be:

  4/3*(sqrt(2)-1) * r

The spline will be an exact quarter circle.  Your spline might look like:

Hope this helps,
John
-- 
ICQ: 46085459


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.